<template>
  <!-- 给按钮注册原生的click事件 -->
  <button @click="clickFn" @mouseenter="enter">
    <slot />
  </button>
</template>

<script>
export default {
  name: 'HmButton',
  methods: {
    clickFn() {
      this.$emit('click')
    },
    enter() {
      this.$emit('mouseenter')
    }
  }
}
</script>

<style>

</style>
